<?php
// +----------------------------------------------------------------------
// | ThinkPHP [ WE CAN DO IT JUST THINK ]
// +----------------------------------------------------------------------
// | Copyright (c) 2006~2016 http://thinkphp.cn All rights reserved.
// +----------------------------------------------------------------------
// | Licensed ( http://www.apache.org/licenses/LICENSE-2.0 )
// +----------------------------------------------------------------------
// | Author: liu21st <liu21st@gmail.com>
// +----------------------------------------------------------------------

use think\Route;
// restful风格API

Route::resource(':version/app','app/:version.APP');
Route::resource(':version/user','app/:version.User');
Route::resource(':version/img','app/:version.Img');
Route::resource(':version/island','app/:version.Island');
Route::resource(':version/strategy','app/:version.Strategy');
Route::resource(':version/line','app/:version.Line');
Route::resource(':version/system','app/:version.System');
Route::resource(':version/shoppingcart','app/:version.ShoppingCart');
Route::resource(':version/order','app/:version.Order');
Route::resource(':version/advert','app/:version.Advert');
Route::resource(':version/collage','app/:version.Collage');
Route::resource(':version/news','app/:version.News');
Route::resource(':version/collection','app/:version.Collection');
Route::resource(':version/nav','app/:version.Nav');
Route::resource(':version/plane','app/:version.Plane');
Route::resource(':version/bargain','app/:version.Bargain');




//AppController
//登录
Route::rule(':version/login','app/:version.App/login');
//微信验证
Route::rule(':version/wxcheck','app/:version.App/wxCheck');
//测试
Route::rule(':version/test','app/:version.App/test');



//UserController
Route::rule(':version/userinfo','app/:version.User/UserInfo');


//ImgController
//海报
Route::rule(':version/create','app/:version.Img/create');
Route::rule(':version/collageposter','app/:version.Img/CreateCollagePoster');


//IslandController[攻略]
//显示全部海岛
Route::rule(':version/islandlist','app/:version.Island/IslandList');
Route::rule(':version/islanddetail','app/:version.Island/IslandDetail');
Route::rule(':version/islandvideodetail','app/:version.Island/IslandVideoDetail');
Route::rule(':version/islandhoteldetail','app/:version.Island/IslandHotelDetail');
Route::rule(':version/islandrestaurantdetail','app/:version.Island/IslandRestaurantDetail');
Route::rule(':version/islanddisportdetail','app/:version.Island/IslandDisportDetail');
Route::rule(':version/islandhot','app/:version.Island/IslandHot');


//StrategyController[攻略]
Route::rule(':version/strategyclass','app/:version.Strategy/StrategyClass');
Route::rule(':version/strategylist','app/:version.Strategy/StrategyList');


//LineController[线路]
Route::rule(':version/linehot','app/:version.Line/LineHot');
Route::rule(':version/linelist','app/:version.Line/LineList');
Route::rule(':version/linedetail','app/:version.Line/LineDetail');
Route::rule(':version/linedetailconfig','app/:version.Line/LineDetailConfig');
Route::rule(':version/addshoppingcart','app/:version.Line/AddShoppingCart');
Route::rule(':version/searchline','app/:version.Line/searchLine');


//SystemController  [系统]
Route::rule(':version/aboutus','app/:version.System/AboutUs');
Route::rule(':version/contactus','app/:version.System/ContactUs');




//ShoppingCartController[购物车]
Route::rule(':version/myshoppingcart','app/:version.ShoppingCart/MyShoppingCart');
Route::rule(':version/delcartline','app/:version.ShoppingCart/DelCartLine');
Route::rule(':version/saveshoppingcart','app/:version.ShoppingCart/SaveShoppingCart');


//OrderController[订单]
Route::rule(':version/myorder','app/:version.Order/MyOrder');
Route::rule(':version/placeorder','app/:version.Order/PlaceOrder');
Route::rule(':version/ordernow','app/:version.Order/OrderNow');
Route::rule(':version/notpay','app/:version.Order/NotPay');
Route::rule(':version/alreadypay','app/:version.Order/AlreadyPay');
Route::rule(':version/alreadyuse','app/:version.Order/AlreadyUse');
Route::rule(':version/notifyurl','app/:version.Order/notifyUrl');
Route::rule(':version/createorder','app/:version.Order/CreateOrder');
Route::rule(':version/payorder','app/:version.Order/notifyUrl');
Route::rule(':version/createplaneorder','app/:version.Order/CreatePlaneOrder');


//AdvertController[广告]
Route::rule(':version/homepage','app/:version.Advert/HomePage');
Route::rule(':version/homeadv','app/:version.Advert/HomeAdv');


//CollageController[团购]
Route::rule(':version/collageInfo','app/:version.Collage/collageInfoByCollageId'); //拼团详情
Route::rule(':version/addCollage','app/:version.Collage/addCollage');//创建团购
Route::rule(':version/toPayCollage','app/:version.Collage/toPayCollage');//团购支付
Route::rule(':version/collageCallBack','app/:version.Collage/collageCallBack');//支付回调
Route::rule(':version/inviteFriends','app/:version.Collage/addInviteFriends'); //邀请朋友拼团
Route::rule(':version/collageLists','app/:version.Collage/collageListsByUserId'); // 团购列表


//NewsController
Route::rule(':version/typelist','app/:version.News/TypeList');
Route::rule(':version/newstype','app/:version.News/NewsType');
Route::rule(':version/newsdetail','app/:version.News/NewsDetail');



//CollectionCollection
Route::rule(':version/collectionline','app/:version.Collection/CollectionLine');
//Route::rule(':version/cancelcollection','app/:version.Collection/CancelCollection');
Route::rule(':version/mycollection','app/:version.Collection/MyCollection');
//获取分销记录
Route::rule(':version/recordsLists','app/:version.Distribution/recordsByUserId');

//企业付款测试
Route::rule(':version/refund','app/:version.Distribution/compantPayment');

//定时任务
Route::rule(':version/timed','app/:version.Collage/timedTask');



//NavController[导航]
Route::rule(':version/navclasslist','app/:version.Nav/NavClassList');
Route::rule(':version/navlist','app/:version.Nav/NavList');


//机票PlaneController
Route::rule(':version/planeticket','app/:version.Plane/PlaneTicket');
Route::rule(':version/planeinfo','app/:version.Plane/PlaneInfo');
Route::rule(':version/planelist','app/:version.Plane/PlaneList');



//砍价线路
Route::rule(':version/bargainlinelist','app/:version.Bargain/BargainLineList');
Route::rule(':version/createbargain','app/:version.Bargain/createBargain');
Route::rule(':version/helpbargain','app/:version.Bargain/helpBargain');